package net.nightwhistler.htmlspanner.tyydextension;

/**
 * 天翼阅读格式下，封面章节信息
 * 
 * @author dave
 * 
 */
public class CoverPageInfo {
	String backgroundColor;
	String backgroundImage;
	String title;
	String subTitle;
	boolean haveData;
	String titleStyle;
	String chapterTitle;

	public String getChapterTitle() {
		return chapterTitle;
	}

	public void setChapterTitle(String chapterTitle) {
		this.chapterTitle = chapterTitle;
	}

	public String getTitleStyle() {
		return titleStyle;
	}

	public void setTitleStyle(String titleStyle) {
		this.titleStyle = titleStyle;
	}

	public boolean isHaveData() {
		return haveData;
	}

	/**
	 * 根据字段值设置封面设置状态
	 */
	public void refreshStatus() {
		if ((backgroundColor != null || backgroundImage != null)
				&& title != null) {
			haveData = true;
		} else {
			haveData = false;
		}
	}

	public void setHaveData(boolean haveData) {
		this.haveData = haveData;
	}

	public String getBackgroundColor() {
		return backgroundColor;
	}

	public void setBackgroundColor(String backgroundColor) {
		this.backgroundColor = backgroundColor;
	}

	public String getBackgroundImage() {
		return backgroundImage;
	}

	public void setBackgroundImage(String backgroundImage) {
		this.backgroundImage = backgroundImage;
	}

	public String getTitle() {
		return title;
	}

	public void setTitle(String title) {
		this.title = title;
	}

	public String getSubTitle() {
		return subTitle;
	}

	public void setSubTitle(String subTitle) {
		this.subTitle = subTitle;
	}

}
